import { IMessageBase } from "../../Framework/MQ/IMessageBase";
import { MessageManager } from "../../Framework/MQ/MessageManager";
import { SerializeStream } from "../../Framework/Serialize/SerializeStream";
import { SeqPlayerItemUpdateHelper } from "./SeqPlayerItemUpdateHelper";
import { SPublicMiniPlayer } from "../Public/SPublicMiniPlayer";
type int = number;
//class SOfficerInfo
    
    export  class SOfficerInfo extends IMessageBase
    {
        constructor(arg1: Boolean=false)
        {
            
            super();if (arg1) 
            {
                MessageManager.instance().regist(this);
            }
            return;
        }

        public /* override */ getType(): int
        {
            return this._type;
        }

        public /* override */ clone(): IMessageBase
        {
            return new SOfficerInfo();
        }

        public /* override */ __write(arg1: SerializeStream): void
        {
            arg1.writeInt(this.position);
            this.player.__write(arg1);
            SeqPlayerItemUpdateHelper.write(arg1, this.playerItemUpdates);
            arg1.writeInt(this.secondCareer);
            arg1.writeInt(this.mount);
            arg1.writeInt(this.fight);
            arg1.writeBool(this.fashionState);
            arg1.writeBool(this.wingState);
            arg1.writeBool(this.fashionWeaponState);
            return;
        }

        public /* override */ __read(arg1: SerializeStream): void
        {
            this.position = arg1.readInt();
            this.player = new SPublicMiniPlayer();
            this.player.__read(arg1);
            this.playerItemUpdates = SeqPlayerItemUpdateHelper.read(arg1);
            this.secondCareer = arg1.readInt();
            this.mount = arg1.readInt();
            this.fight = arg1.readInt();
            this.fashionState = arg1.readBool();
            this.wingState = arg1.readBool();
            this.fashionWeaponState = arg1.readBool();
            return;
        }

        public /* const */_type: int=1000;

        public /* var */position: int;

        public /* var */player: SPublicMiniPlayer;

        public /* var */playerItemUpdates: Array<any>;

        public /* var */secondCareer: int;

        public /* var */mount: int;

        public /* var */fight: int;

        public /* var */fashionState: Boolean;

        public /* var */wingState: Boolean;

        public /* var */fashionWeaponState: Boolean;

        public static /* var */_regist: SOfficerInfo;
    }

            SOfficerInfo._regist = new SOfficerInfo(true);
        